package com.im.partchat.ui.activity.more;

import android.text.TextUtils;
import android.widget.LinearLayout;

import com.im.partchat.R;
import com.im.partchat.base.BaseActivity;
import com.just.library.AgentWeb;

import butterknife.BindView;

public class PayDuesWebViewActivity extends BaseActivity {


    @BindView(R.id.ll_play)
    LinearLayout llPlay;
    AgentWeb agentWeb;

    @Override
    protected int getLayoutId() {
        return R.layout.activity_pay_dues_web_view;
    }

    @Override
    protected void initData() {
        String title = getIntent().getStringExtra("title");
        String url = getIntent().getStringExtra("url");
        if (!TextUtils.isEmpty(title)) {
            setTitle(title);
        }

        agentWeb = AgentWeb.with(this)//传入Activity
                .setAgentWebParent(llPlay, new LinearLayout.LayoutParams(-1, -1))
                .useDefaultIndicator()// 使用默认进度条
                .defaultProgressBarColor() // 使用默认进度条颜色
                .setReceivedTitleCallback(null) //设置 Web 页面的 title 回调
                .createAgentWeb()//
                .ready()
                .go(url);

    }

    @Override
    public void onLoadDataSuccess(Object o, String flag) {

    }


}
